<?php

namespace app\model\admin\sgz;

use laytp\BaseModel;
use think\model\concern\SoftDelete;

class SgzTeam extends BaseModel
{
    use SoftDelete;
    protected $name = 'sgz_team';

    public function teamGenerals(){
        return $this->belongsToMany("SgzGenerals","SgzTeamGenerals","generals_id","team_id");
    }

    public function user(){
        return $this->hasOne("SgzUser","id","user_id");
    }
}